﻿using PRO.ORM;
using System;
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Text;

namespace PRO.Permission.Entity
{
    [Entity(TableName="PermissionGroup")]
    public class PermissionGroup:BaseEntity
    {
        private int _ID = -1;
        /// <summary>
        /// 权限分组ID
        /// </summary>
        [EntityAttribute(SqlDbType = SqlDbType.Int,Len = 4,PrimaryKey = true)]
        public int ID
        {
            get { return _ID; }
            set { _ID = value; }
        }
        private string _GroupTitle;
        /// <summary>
        /// 权限分组名称
        /// </summary>
        [Entity(SqlDbType = SqlDbType.NVarChar,Len = 100)]
        public string GroupTitle
        {
            get { return _GroupTitle; }
            set { _GroupTitle = value; }
        }
        private string _GroupNote;
        /// <summary>
        /// 权限分组说明
        /// </summary>
        [EntityAttribute(SqlDbType = SqlDbType.NVarChar,Len = 250)]
        public string GroupNote
        {
            get { return _GroupNote; }
            set { _GroupNote = value; }
        }
        private List<PermissionItem> _PermissionItems;
        /// <summary>
        /// 当前权限分组下的权限集合
        /// </summary>
        public List<PermissionItem> PermissionItems
        {
            get { return _PermissionItems; }
            set { _PermissionItems = value; }
        }
    }
}
